package com.zhuiyun.educations.api.User.entity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 
 * </p>
 *
 * @author yangze
 * @since 2023-06-15
 */
@Getter
@Setter
  public class User implements Serializable {

    private static final long serialVersionUID = 1L;

      /**
     * 主键id(杨泽)
     */
      @Id
      @GeneratedValue(strategy = GenerationType.IDENTITY)
      private Integer id;

      /**
     * 用户名
     */
      private String userName;

      /**
     * 登录名（唯一）
     */
      private String loginName;

      /**
     * 密码
     */
      private String password;

      /**
     * 电话号
     */
      private String phone;

      /**
     * 邮箱
     */
      private String email;

      /**
     * 创建时间
     */
      @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
      @DateTimeFormat(pattern ="yyyy-MM-dd" )
      private Date createTime;

      /**
     * 修改时间
     */
      @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
      @DateTimeFormat(pattern ="yyyy-MM-dd" )
      private Date updateTime;

      /**
     * 头像
     */
      private String avatarUrl;

      /**
     * 地址
     */
      private String address;


}
